#pragma once

#include <memory>
#include "rtda/frame.h"
#include "native/registry.h"

namespace jvm {
    namespace lang {

        class ObjectNative {
        private:
            static const std::string JL_OBJECT;

        public:
            static void getClass(std::shared_ptr<rtda::Frame> pframe);
            static void hashCode(std::shared_ptr<rtda::Frame> pframe);
            static void clone(std::shared_ptr<rtda::Frame> pframe);

            static void init() {
                native::Registry::registerMethod(JL_OBJECT, "getClass", "()Ljava/lang/Class;", getClass);
                native::Registry::registerMethod(JL_OBJECT, "hashCode", "()I", hashCode);
                native::Registry::registerMethod(JL_OBJECT, "clone", "()Ljava/lang/Object;", clone);
            }

        };

    } // namespace lang
} // namespace jvm